package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import java.util.Date;

import static org.jsola.hr.example.NewsInfoExample.E_BROWSE_NUM;
import static org.jsola.hr.example.NewsInfoExample.E_CONTENT;
import static org.jsola.hr.example.NewsInfoExample.E_CONTENT_HAS_STYLE;
import static org.jsola.hr.example.NewsInfoExample.E_IS_PUSH;
import static org.jsola.hr.example.NewsInfoExample.E_NEWS_TYPE_ID;
import static org.jsola.hr.example.NewsInfoExample.E_PUSH_DATE;
import static org.jsola.hr.example.NewsInfoExample.E_PUSH_USER_ID;
import static org.jsola.hr.example.NewsInfoExample.E_PUSH_USER_NAME;
import static org.jsola.hr.example.NewsInfoExample.E_TITLE;
import static org.jsola.hr.example.NewsInfoExample.E_TO_URL;
import static org.jsola.hr.example.NewsInfoExample.M_CONTENT_HAS_STYLE_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_CONTENT_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_NEWS_TYPE_ID_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_PUSH_USER_ID_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_PUSH_USER_NAME_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_TITLE_MAX;
import static org.jsola.hr.example.NewsInfoExample.M_TO_URL_MAX;
import static org.jsola.hr.example.NewsInfoExample.N_BROWSE_NUM;
import static org.jsola.hr.example.NewsInfoExample.N_CONTENT;
import static org.jsola.hr.example.NewsInfoExample.N_CONTENT_HAS_STYLE;
import static org.jsola.hr.example.NewsInfoExample.N_IS_PUSH;
import static org.jsola.hr.example.NewsInfoExample.N_NEWS_TYPE_ID;
import static org.jsola.hr.example.NewsInfoExample.N_PUSH_DATE;
import static org.jsola.hr.example.NewsInfoExample.N_PUSH_USER_ID;
import static org.jsola.hr.example.NewsInfoExample.N_PUSH_USER_NAME;
import static org.jsola.hr.example.NewsInfoExample.N_TITLE;
import static org.jsola.hr.example.NewsInfoExample.N_TO_URL;

/**
 * 官网信息的类型
 *
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【官网信息的类型】的参数")
@Data
public class NewsInfoAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_BROWSE_NUM, example = E_BROWSE_NUM)
    private Integer browseNum;

    @ApiModelProperty(notes = N_NEWS_TYPE_ID, example = E_NEWS_TYPE_ID)
    @Length(max = 32, message = M_NEWS_TYPE_ID_MAX)
    private String newsTypeId;

    @ApiModelProperty(notes = N_TITLE, example = E_TITLE)
    @Length(max = 2147483647, message = M_TITLE_MAX)
    private String title;

    @ApiModelProperty(notes = N_CONTENT, example = E_CONTENT)
    @Length(max = 2147483647, message = M_CONTENT_MAX)
    private String content;

    @ApiModelProperty(notes = N_CONTENT_HAS_STYLE, example = E_CONTENT_HAS_STYLE)
    @Length(max = 2147483647, message = M_CONTENT_HAS_STYLE_MAX)
    private String contentHasStyle;

    @ApiModelProperty(notes = N_TO_URL, example = E_TO_URL)
    @Length(max = 200, message = M_TO_URL_MAX)
    private String toUrl;

    @ApiModelProperty(notes = N_IS_PUSH, example = E_IS_PUSH)
    private Boolean isPush;

    @ApiModelProperty(notes = N_PUSH_DATE, example = E_PUSH_DATE)
    private Date pushDate;

    @ApiModelProperty(notes = N_PUSH_USER_ID, example = E_PUSH_USER_ID)
    @Length(max = 32, message = M_PUSH_USER_ID_MAX)
    private String pushUserId;

    @ApiModelProperty(notes = N_PUSH_USER_NAME, example = E_PUSH_USER_NAME)
    @Length(max = 50, message = M_PUSH_USER_NAME_MAX)
    private String pushUserName;


}

